home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 32
/
Aminet 32 (1999)(Schatztruhe)[!][Aug 1999].iso
/
Aminet
/
hard
/
drivr
/
ScanTek4_5.lha
/
ScanTek
/
ScanTek-Install
< prev
next >
Wrap
Text File
|
1999-05-04
|
16KB
|
690 lines
;------------------------------------------------------------------------
;
; This is the ScanTek Installer Script
;
; $VER: ScanTek-Install 1.5 (03.05.99) Waldemar Zöhner
;
; Copyright © Waldemar Zöhner 1998/99
; Inspired by the Surfer-Install Script provided with the Installer
; Archive.
;
; This ScanTek install script is localized for English and German
; Dieses ScanTek Installationsskript ist für Englisch und Deutsch
; ausgelegt.
;------------------------------------------------------------------------
; Always clean up (A not so famous chinese verse)
;
(onerror (P_CleanUp))
;------------------------------------------------------------------------
(user 1); starting user level
(set #scantekversion "ScanTek 4.5")
(set #scantekdestdir "RAM:")
(set #scantekdirname "ScanTek")
(set #scantekkeyname "ScanTek.key")
(set #cpuopt_dir "CPUopt")
(set cpu (database "cpu"))
(set #cpu 0) ; the default
(if (= cpu 68010) (set #cpu 1)) (if (= cpu 68020) (set #cpu 2))
(if (= cpu 68030) (set #cpu 3)) (if (= cpu 68040) (set #cpu 4))
(if (= cpu 68060) (set #cpu 5))
(set #copykeyfile 0)
;available catalogs
(set #engcat_str "english")
(set #deucat_str "deutsch")
(set #dancat_str "dansk")
;available documents
(set #engdoc_str "ScanEnglish.guide")
(set #deudoc_str "ScanDeutsch.guide")
;-------- English --------
;this is the default for all installations
(set #catalog-mask 0)
(set #doc-mask 1)
(set #reginfo-prompt
(cat "\nA ScanTek keyfile was found\n\n"
"Take care about the commitments you have made:\n\n"
"You have read the section 'Copyrights' in the manual and have\n"
"agreed with the conditions. Specifically, with your signature,\n"
"you have committed on installing the keyfile only on one\n"
"computer and not giving it to others.\n\n"
"I accept the commitments.\n"
))
(set #reginfo-help
(cat "Please check if you can confirm the required commitments. "
"If you can´t confirm then you are not allowed to install and "
"use the personalized keyfile."
))
(set #wrongversion
(cat "Caution! You have an old version of the program 'Installer' "
"on your Amiga!\n\nThe installation script may lead to a incomplete installation.\n"
"Please, upgrade the Installer to version 42.9 or higher."
))
(set #welcome1
(cat ("%s\n" #scantekversion)
"The scanner driver for Microtek, Highscreen and Mustek Flatbed Scanner\n"
"© Copyright 1995/96/97/98/99 Waldemar Zöhner"
))
(set #welcome
(cat "Welcome to the Installation of\n"
#welcome1
))
(set #install_init "Preparing Installation.")
(set #scantekdestdir-prompt "\nPlease select the drawer where the drawer 'ScanTek' should be created.\n")
(set #scantekdestdir-help "Typically, 'Work:' is selected as destination.")
(set #filedirclash
(cat "Installation error!\nYou have choosen the path to a file.\n"
"It cannot be used as the Scantek directory!\n"
"Please restart the installation in a different directory."
))
(set #cleanupstr "Performing CleanUp")
(set #askcpu-prompt
(cat "\nCPU Verification:\nWhat CPU does the machine use that you are installing ScanTek on?\n"
"The installer assumes:\n"
))
(set #askcpu-help
(cat "Here you have the opportunity to select a CPU specific "
"ScanTek program version.\n\nCaution:\n"
"If you choose a CPU that is higher than the available one "
"than this leads to a system crash."
))
(set #askcatalog-prompt
(cat "\nWhich languages should be installed for ScanTek?\n"
"You can choose more than one language.\n"
))
(set #askcatalog-help
(cat "You can choose different languages. The actual used language "
"is determined during startup of Scantek out of your LOCALE settings."
))
(set #askdoc-prompt
(cat "\nWhich documents (guide files) should be installed?\n"
"You can choose more than one document.\n"
))
(set #askdoc-help
(cat "You can choose different documents. As a rule of thumb you need only "
"one."
))
(set #cheers
(cat "\n\n\nInstallation complete. Have much fun with\n"
#welcome1
))
;-------- Deutsch --------
(if (= @language "deutsch")
(
(set #catalog-mask 1)
(set #doc-mask 2)
(set #wrongversion
(cat "Achtung! Sie benutzen eine alte Version des Programmes 'Installer' "
"auf Ihrem Amiga!\n\nEine erfolgreiche Installation ist nicht gewährleistet.\n"
"Bitte erweitern Sie Ihre Konfiguration auf Installer 42.9. oder besser\n\n"
))
(set #reginfo-prompt
(cat "\nEs wurde ein ScanTek Keyfile entdeckt\n\n"
"Bitte beachten Sie Ihre eingegangene Verpflichtung:\n\n"
"Sie haben in der Scantek Anleitung den Abschnitt 'Copyrights' gelesen\n"
"und akzeptieren die Bedingungen. Insbesondere haben Sie sich mit Ihrer\n"
"Unterschrift dazu verpflichtet, das personalisierte Keyfile nur auf einem\n"
"Rechner zu installieren und nicht an andere weiterzugeben.\n"
"\nIch akzeptiere die Bedingungen\n"
))
(set #reginfo-help
(cat "Prüfen Sie ob Sie die geforderten Verpflichtungen erfüllen und damit "
"einverstanden sind. Wenn dies nicht der Fall ist, dann müssen Sie "
"die Installation des personifizierten Keyfiles ablehnen."
))
(set #welcome1
(cat ("%s\n" #scantekversion)
"Der Scanner Treiber für Microtek, Highscreen und Mustek Flachbett Scanner\n"
"© Copyright 1995/96/97/98/99 Waldemar Zöhner"
))
(set #welcome
(cat "Willkommen zur Installation von\n"
#welcome1
))
(set #install_init "Bereite Installation vor.")
(set #scantekdestdir-prompt "\nBitte geben Sie die Schublade an, in der die Schublade 'ScanTek' angelegt werden soll.\n")
(set #scantekdestdir-help "Üblicherweise wird ScanTek nach 'Work:' installiert.")
(set #filedirclash
(cat "\nInstallation Fehler!\nSie habe den Pfad auf eine Datei gewählt.\n"
"Darum kann die Schublade ScanTek nicht erstellt werden.\n"
"Bitte die Installation in einer anderen Schublade noch einmal durchführen"
))
(set #cleanupstr "\nBeseitige die Installationshilfen")
(set #askcpu-prompt
(cat "\nCPU Prüfung:\n"
"Welche CPU steuert den Rechner auf dem Sie ScanTek installieren wollen?\n"
"Der Installer hat den folgenden Typ erkannt:\n"
))
(set #askcpu-help
(cat "Hier habe Sie die Möglichkeit abhängig von Ihrem verwendeten "
"Prozessor ein bestimmte optimierte ScanTek Programmvariante"
"zu wählen.\n\nAchtung\n"
"Wählen Sie hier einen Prozessor mit einer höheren Version "
"als Sie tatsächlich besitzen, dann wird dies unweigerlich zum "
"Absturz ihres Rechners bei der Ausführung von ScanTek führen."
))
(set #askcatalog-prompt
(cat "\nWelche Sprachen sollen für ScanTek installiert werden\n"
"Es können mehrere Sprachen angewählt werden.\n"
))
(set #askcatalog-help
(cat "Hier können Sie verschiedene Sprachen anwählen. Die tatsächlich "
"benutzte Sprache wird während des Hochfahrens von ScanTek aus den "
"LOCALE Einstellungen ermittelt.\n"
))
(set #askdoc-prompt
(cat "\nWelche Dokumentationen (Guidedateien) sollen installiert werden?\n"
"Es können mehrere angewählt werden.\n"
))
(set #askdoc-help
(cat "Hier können Sie verschiedene Dokumentationen anwählen. Normalerweise "
"reicht es aus, wenn Sie nur eine Dokumentation wählen."
))
(set #cheers
(cat "\n\n\nInstallation abgeschlossen. Viel Spaß mit\n"
#welcome1
))
)
) ; if
;-------- Dansk --------
(if (= @language "dansk")
(
(set #catalog-mask 2)
(set #doc-mask 1)
(set #reginfo-prompt
(cat "\nEn ScanTek keyfile blev fundet\n\n"
"Vær forsigtig med de forpligtelser du har gjort dig:\n\n"
"Du har læst afsnittet 'Copyrights' i manualen og er indforstået\n"
"med betingelserne. Helt bestemt har du, med din underskrift,\n"
"forpliget dig til kun at installere keyfilen på én computer,\n"
"og ikke give den til andre.\n\n"
"Jeg accepterer forpligtelserne.\n"
))
(set #reginfo-help
(cat "Bekræft venligst om du kan stå inde for de krævede betingelser. "
"Hvis du ikke kan stå inde for dem, så har du ikke lov til at "
"installere og bruge den personlige keyfile."
))
(set #wrongversion
(cat "Advarsel! Du har en gammel version af programmet 'Installer' "
"på din Amiga!\n\nInstallationsskriptet kan føre til en "
"inkorrekt installation.\n"
"Opgradér venligst 'Installer' til version 42.9 eller højere."
))
(set #welcome1
(cat ("%s\n" #scantekversion)
"Scanner driver til Microtek, Highscreen og Mustek Flatbed Scannere\n"
"© Copyright 1995/96/97/98/99 Waldemar Zöhner"
))
(set #welcome
(cat "Velkommen til installationen af\n"
#welcome1
))
(set #install_init "Klargører Installation.")
(set #scantekdestdir-prompt "\nVælg venligst en skuffe, hvor skuffen 'ScanTek' skal oprettes.\n")
(set #scantekdestdir-help "Typisk er 'Work:' valgt som destination.")
(set #filedirclash
(cat "Installationsfejl!\nDu har valgt stien til en fil.\n"
"Den kan ikke benyttes som Scantek skuffe!\n"
"Genstart venligst installationen i en anden skuffe."
))
(set #cleanupstr "Udfører Oprydning")
(set #askcpu-prompt
(cat "\nCPU Verificering:\nHvilken CPU har maskinen, du installerer ScanTek på?\n"
"Installationsprogrammet formoder:\n"
))
(set #askcpu-help
(cat "Her har du mulighed for at vælge en CPU specifik udgave, "
"af ScanTek programmet.\n\nAdvarsel:\n"
"Hvis du vælger en CPU som er højere, end den der er tilgængelig, "
"vil det lede til et system nedbrud."
))
(set #askcatalog-prompt
(cat "\nHvilke(t) sprog ønsker du at installere til ScanTek?\n"
"Du kan godt vælge mere end ét sprog.\n"
))
(set #askcatalog-help
(cat "Du kan vælge forskellige sprog. Det benyttede sprog bliver "
"valgt under opstart af Scantek ud fra dine LOCALE indstillinger."
))
(set #askdoc-prompt
(cat "\nHvilke(t) dokument(er) (guide filer) ønsker du at installere?\n"
"Du kan godt vælge mere en ét dokument.\n"
))
(set #askdoc-help
(cat "Du kan vælge forskellige dokumenter. Som hovedregel har du kun "
"brug for ét."
))
(set #cheers
(cat "\n\n\nInstallationen er færdig. Mor dig godt med\n"
#welcome1
))
)
)
;------------------------------------------------------------------------
; Cleanup any temporary mess we created
(procedure P_CleanUp
; Nothing to cleanup
(message #cleanupstr)
;(delete (tackon @default-dest ".tempinstall") (all) (optional "force"))
) ; P_CleanUp
;------------------------------------------------------------------------
(procedure P_CopyDirLib
; #PCL_srcfiledir
; #PCL_destdir
;
; its a directory
(makedir (tackon #PCL_destdir #PCL_srcfiledir))
(foreach #PCL_srcfiledir "#?"
(
(if (> 0 @each-type)
(
;this is a file
(copylib
(source (tackon #PCL_srcfiledir @each-name))
(dest (tackon #PCL_destdir #PCL_srcfiledir))
(optional "force" "askuser")
)
)
)
)
)
)
;------------------------------------------------------------------------
(procedure P_CopyFileLib
; #PCL_srcfiledir
; #PCL_destdir
;
; its a file
(copylib
(source #PCL_srcfiledir)
(dest #PCL_destdir)
(infos)
(optional "force" "askuser")
)
)
;------------------------------------------------------------------------
(procedure P_CopyFileNewLib
; #PCL_srcfiledir
; #PCL_destdir
; #PCL_destfile
;
; its a file
(copylib
(source #PCL_srcfiledir)
(dest #PCL_destdir)
(infos)
(newname #PCL_destfile)
(optional "force" "askuser")
)
)
;------------------------------------------------------------------------
(procedure P_CopyDir
; #PCL_srcfiledir
; #PCL_destdir
;
; its a directory
(makedir (tackon #PCL_destdir #PCL_srcfiledir))
(copyfiles
(source #PCL_srcfiledir)
(dest (tackon #PCL_destdir #PCL_srcfiledir))
(all)
(optional "force" "askuser")
)
)
;------------------------------------------------------------------------
(procedure P_CopyFile
; #PCL_srcfiledir
; #PCL_destdir
;
(copyfiles
(source #PCL_srcfiledir)
(dest #PCL_destdir)
(infos)
(optional "force" "askuser")
)
)
;------------------------------------------------------------------------
; Installer 42.9 or better prefered
(if (< @installer-version 2752521)
(
; Notify user about the old version
(message #wrongversion)
)
)
; find out how the user wants to install things
(welcome #welcome)
(complete 0)
(working #install_init)
(complete 4)
(set #scantekdir
(tackon
(expandpath
(askdir
(prompt #scantekdestdir-prompt)
(help #scantekdestdir-help)
(default @default-dest)
; (default #scantekdestdir)
)
)
#scantekdirname
)
)
(complete 10)
(if (= 1 (exists #scantekdir))
;abort the current installation,
;because there exists a file with our prefered name
( (P_CleanUp)
(abort (#filedirclash #scantekdir))
)
)
(complete 12)
; not available yet
;(set #cpuchoice
; (askchoice (choices "68000" "68010" "68020" "68030" "68040" "68060")
; (prompt #askcpu-prompt)
; (help #askcpu-help)
; (default #cpu)
; )
;)
;
(complete 17)
(set #catalogchoice-mask
(askoptions
(choices #deucat_str #dancat_str)
(prompt #askcatalog-prompt)
(help #askcatalog-help)
(default #catalog-mask)
)
)
(complete 22)
;choose the documentation
(set #docchoice-mask
(askoptions
(choices #engdoc_str #deudoc_str)
(prompt #askdoc-prompt)
(help #askdoc-help)
(default #doc-mask)
)
)
(if (= 1 (exists #scantekkeyname))
(
set #copykeyfile (askbool (prompt #reginfo-prompt) (help #reginfo-help) (default 1))
)
)
(complete 27)
; create directory whether it exists or not
(makedir #scantekdir (infos))
(set @default-dest #scantekdir)
(complete 30)
(set #PCL_destdir #scantekdir);
(set #counter 0)
(while (> 1 #counter)
(
(set #PCL_srcfiledir (select #counter "Rexx"))
(set #PCL_destdir #scantekdir);
(P_CopyDirLib)
(set #counter (+ #counter 1))
)
)
(complete 40)
; not available yet
;(set #PCL_srcfiledir (select #cpuchoice "ScanTek" "ScanTek" "ScanTek_68020" "ScanTek_68030" "ScanTek_68040" "ScanTek_68060"))
;(if (> #cpuchoice 1)
; (
; (set #PCL_srcfiledir (tackon #cpuopt_dir #PCL_srcfiledir))
; )
;)
(set #PCL_srcfiledir "ScanTek")
(set #PCL_destfile "ScanTek")
(set #PCL_destdir #scantekdir)
(P_CopyFileNewLib)
(complete 50)
(set #counter 0)
(while (> 3 #counter)
(
(set #PCL_srcfiledir (select #counter "Images" "Temp" "Gamma"))
(set #PCL_destdir #scantekdir);
(P_CopyDir)
(set #counter (+ #counter 1))
)
)
(complete 60)
(set #counter 0)
(while (> 4 #counter)
(
(set #PCL_srcfiledir (select #counter "Orderform" "Bestellformular" "ReadMe" "LiesMich"))
(set #PCL_destdir #scantekdir);
(P_CopyFile)
(set #counter (+ #counter 1))
)
)
(complete 70)
(makedir (tackon #scantekdir "Documents"))
(set #counter 0)
(while (> 2 #counter)
(
(set #PCL_srcfiledir (tackon "Documents" (select #counter #engdoc_str #deudoc_str)))
(set #PCL_destdir (tackon #scantekdir "Documents"))
(if (IN #docchoice-mask #counter)
(
(P_CopyFileLib)
)
)
(set #counter (+ #counter 1))
)
)
(complete 80)
(makedir (tackon #scantekdir "Catalogs"))
(set #counter 0)
(while (> 2 #counter)
(
(set #cat_path (tackon "Catalogs" (select #counter #deucat_str #dancat_str)))
(set #PCL_srcfiledir #cat_path)
(set #PCL_destdir (tackon #scantekdir #cat_path))
(if (IN #catalogchoice-mask #counter)
(
(makedir #PCL_srcfiledir)
(set #PCL_srcfiledir (tackon #PCL_srcfiledir "ScanTek.catalog"))
(P_CopyFileLib)
)
)
(set #counter (+ #counter 1))
)
)
(complete 90)
(set #counter 0)
(while (> 4 #counter)
(
(set #PCL_srcfiledir (select #counter "Images.info" "Documents.info" "Gamma.info" "Rexx.info" "Catalogs.info"))
(set #PCL_destdir #scantekdir)
(P_CopyFile)
(set #counter (+ #counter 1))
)
)
(complete 95)
(if (= 1 #copykeyfile)
(
(set #PCL_srcfiledir #scantekkeyname)
(set #PCL_destdir #scantekdir)
(P_CopyFile)
)
)
(complete 99)
; remove the temporarily need executables
(complete 100)
(exit #cheers)